package com.Pounds.InitAll;

import com.Pounds.dao.DaoEvent.DaoEvent;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.*;

import org.springframework.context.ApplicationContext;
import org.springframework.stereotype.*;

@Component
public class InitAll implements CommandLineRunner {
    @Autowired
    ApplicationContext applicationContext;

    public void run ( String ... args ) {
        applicationContext.publishEvent(new DaoEvent(this, DaoEvent.MySQLEventType.TestAndInitMySQL));
    }
}
